This section describes the functions that let you set and retrieve less commonly used fields in the window record.
Sets a picture for the Window Manager to draw in a window's content region.
pascal void SetWindowPic (WindowPtr theWindow,
PicHandle pic);
The SetWindowPic function stores in a window's window record a handle to a picture to be drawn in the window. When the window's content region must be updated, the Window Manager then draws the picture or part of the picture, as necessary, instead of generating an update event.
The CloseWindow (CloseWindow) and DisposeWindow (DisposeWindow) functions assume that any picture pointed to by the window record field windowPic is stored as data, not as a resource. If your application uses a picture stored as a resource, you must release the memory it occupies by calling the Resource Manager's ReleaseResource function and set the WindowPic field to nil before you close the window.
Returns a handle to a window's picture.
pascal PicHandle GetWindowPic (WindowPtr theWindow);
The GetWindowPic function returns a handle to the picture to be drawn in a specified window's content region. The handle must have been stored previously with the SetWindowPic function (SetWindowPic) .
Sets the refCon field of a window record.
pascal void SetWRefCon (WindowPtr theWindow,
long data);
Returns the reference constant from a window's window record.
pascal long GetWRefCon (WindowPtr theWindow);
Returns a window's variation code.
pascal short GetWVariant (WindowPtr theWindow);
The GetWVariant function returns the variation code of the specified window. Depending on the window's window definition function, the result of GetWVariant can represent one of the standard window types or a variation code defined by your own window definition function.
See "Variant Codes" for a detailed description of variation codes.